<ix-modal-header
  [requiredRoles]="requiredRoles"
  [title]="'Clone Boot Environment' | translate"
  [loading]="isLoading()"
></ix-modal-header>

<mat-card>
  <mat-card-content>
    <form
      class="ix-form-container"
      [formGroup]="formGroup"
      (submit)="onSubmit()"
    >
      <ix-fieldset [title]="'Settings' | translate">
        <ix-input
          formControlName="target"
          [label]="'Name' | translate"
          [required]="true"
          [tooltip]="tooltips.name | translate"
        ></ix-input>

        <ix-input
          formControlName="source"
          [label]="'Source' | translate"
          [required]="true"
          [tooltip]="tooltips.source | translate"
        ></ix-input>
      </ix-fieldset>

      <ix-form-actions>
        <button
          *ixRequiresRoles="requiredRoles"
          mat-button
          type="submit"
          color="primary"
          ixTest="save"
          [disabled]="formGroup.invalid || isLoading()"
        >
          {{ 'Save' | translate }}
        </button>
      </ix-form-actions>
    </form>
  </mat-card-content>
</mat-card>
